<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- saved from url=(0049)http://www.helenkellersinstitute.org/sitemap.html -->
<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

<title>Welcome to Helen Keller's Institute</title>
<link href="./Welcome to Helen Keller's Institute_files/style.css" rel="stylesheet" type="text/css">
<script type="text/javascript" async="" src="./Welcome to Helen Keller's Institute_files/ga.js"></script><script type="text/javascript">

  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-8968519-1']);
  _gaq.push(['_trackPageview']);

  (function() {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  })();

</script>
</head>
<body>
<div id="fb-root"></div>
<script>(function(d, s, id) {
  var js, fjs = d.getElementsByTagName(s)[0];
  if (d.getElementById(id)) return;
  js = d.createElement(s); js.id = id;
  js.src = "//connect.facebook.net/en_US/all.js#xfbml=1";
  fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<div id="main">
<div id="banner">
<div id="bannerleft">
</div>
<div id="bannerright">
</div>
</div>
<div id="menu">
<ul>
<li><a href="http://www.helenkellersinstitute.org/about%20us.html">Home</a>
<li><a href="http://www.helenkellersinstitute.org/about%20us.html">Java</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/facility.html">CoreJava</a></li>
<li><a href="http://www.helenkellersinstitute.org/faculty.html">Jdbc</a></li>
<li><a href="http://www.helenkellersinstitute.org/executive%20committe.html">Servlets</a></li>
<li><a href="http://www.helenkellersinstitute.org/successstories.html">Jsp</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">Jstl</a></li>
<li><a href="http://www.helenkellersinstitute.org/facility.html">Jms</a></li>
<li><a href="http://www.helenkellersinstitute.org/successstories.html">Ajax</a></li>
<li><a href="http://www.helenkellersinstitute.org/r&w.html">Xml</a></li>
</ul>
<li><a href="http://www.helenkellersinstitute.org/courses.html">FrameWorks</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/speech%20and%20hearing.html">Struts 1.x</a></li>
<li><a href="http://www.helenkellersinstitute.org/speech%20and%20hearing.html">Struts 2.x</a></li>
<li><a href="http://www.helenkellersinstitute.org/special%20edu.html">Hibernate</a></li>
<li><a href="http://www.helenkellersinstitute.org/mba.html">Spring</a></li>
<li><a href="http://www.helenkellersinstitute.org/hearing%20impired.html">Ibatis</a></li>
<li><a href="http://www.helenkellersinstitute.org/special%20school.html">Jsf</a></li>
<li><a href="http://www.helenkellersinstitute.org/r&w.html">Webservices</a></li>
<li><a href="http://www.helenkellersinstitute.org/vip.html">Soa</a></li>
</ul>
<li><a href="http://www.helenkellersinstitute.org/courses.html">Tools</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/speech%20and%20hearing.html">Ant</a></li>
<li><a href="http://www.helenkellersinstitute.org/special%20edu.html">Cvs</a></li>
<li><a href="http://www.helenkellersinstitute.org/mba.html">Log4j</a></li>
<li><a href="http://www.helenkellersinstitute.org/hearing%20impired.html">Junit</a></li>
<li><a href="http://www.helenkellersinstitute.org/special%20school.html">Jasper reports</a></li>
<li><a href="http://www.helenkellersinstitute.org/r&w.html">I reports</a></li>
<li><a href="http://www.helenkellersinstitute.org/r&w.html">Lucene</a></li>
<li><a href="http://www.helenkellersinstitute.org/r&w.html">ITextPdf</a></li>
</ul>
</li>
<li><a href="http://www.helenkellersinstitute.org/courses.html">DesignTools</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/speech%20and%20hearing.html">Html</a></li>
<li><a href="http://www.helenkellersinstitute.org/special%20edu.html">Css</a></li>
<li><a href="http://www.helenkellersinstitute.org/mba.html">JavaScript</a></li>
<li><a href="http://www.helenkellersinstitute.org/hearing%20impired.html">Jquery</a></li>
<li><a href="http://www.helenkellersinstitute.org/special%20school.html">Dojo</a></li>
</ul>
<li><a href="http://www.helenkellersinstitute.org/photogallery2.html">Servers</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/awards.html">Tomcat</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">Weblogic</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">WebSphere</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralcamps.html">Glassfish</a></li>
<li><a href="http://www.helenkellersinstitute.org/cultural.html">Jboss</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">Jetty</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">Reattore</a></li>
</ul>
<li><a href="http://www.helenkellersinstitute.org/photogallery2.html">IDE's</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">NetBeans</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralcamps.html">MyEclipse</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralcamps.html">JBuilder</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">EditPlus</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">DreamWeaver</a></li>
</ul>
<li><a href="http://www.helenkellersinstitute.org/photogallery2.html">Examples</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/awards.html">Jdbc</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">Sevlets&Jsp</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralcamps.html">Struts</a></li>
<li><a href="http://www.helenkellersinstitute.org/cultural.html">Hibernate</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralschool.html">Spring</a></li>
<li><a href="http://www.helenkellersinstitute.org/clippings.html">Webservices</a></li>
<li><a href="http://www.helenkellersinstitute.org/kadapa.html">JavaScript</a></li>
<li><a href="http://www.helenkellersinstitute.org/lions.html">Jquery</a></li>
<li><a href="http://www.helenkellersinstitute.org/vip.html">Dojo</a></li>
</ul>
<li><a href="http://www.helenkellersinstitute.org/photogallery2.html">InterviewQ&A</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/awards.html">My Experience</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">CoreJava</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralcamps.html">Jdbc</a></li>
<li><a href="http://www.helenkellersinstitute.org/cultural.html">Servlets</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralschool.html">Jsp</a></li>
<li><a href="http://www.helenkellersinstitute.org/clippings.html">Struts</a></li>
<li><a href="http://www.helenkellersinstitute.org/kadapa.html">Hibernate</a></li>
<li><a href="http://www.helenkellersinstitute.org/lions.html">Spring</a></li>
<li><a href="http://www.helenkellersinstitute.org/vip.html">Webservices</a></li>
</ul>
<li><a href="http://www.helenkellersinstitute.org/photogallery2.html">Exceptions</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">CoreJava</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralcamps.html">Jdbc</a></li>
<li><a href="http://www.helenkellersinstitute.org/cultural.html">Servlets</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralschool.html">Jsp</a></li>
<li><a href="http://www.helenkellersinstitute.org/clippings.html">Struts</a></li>
<li><a href="http://www.helenkellersinstitute.org/kadapa.html">Hibernate</a></li>
<li><a href="http://www.helenkellersinstitute.org/lions.html">Spring</a></li>
</ul>
<li><a href="http://www.helenkellersinstitute.org/photogallery2.html">More</a>
<ul>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">Practice</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralcamps.html">3+ exp tips</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralcamps.html">DS with java</a></li>
<li><a href="http://www.helenkellersinstitute.org/ruralcamps.html">SqlTutorial</a></li>
<li><a href="http://www.helenkellersinstitute.org/distribution.html">NoSql</a></li>
<li><a href="http://www.helenkellersinstitute.org/cultural.html">Unix</a></li>
<li><a href="http://www.helenkellersinstitute.org/cultural.html">Computer Tips</a></li>
</ul>
</li>
</div>
<div class="clear"></div>
<div id="bannermenu">
<div id="sidemenu">
<!--add 2-->
</div>
<div id="sidemenu">
<!--add 3-->
</div>
</div>
<div id="welcomemiddle">
<!--<hr>-->
<div id="addmenu">
<div id="searchmenu">
search
</div>
<div id="leftmenu">

</div>
<div id="leftmenu">

</div>
<div id="leftmenu">

</div>
<div id="leftmenu">

</div>
<div id="leftmenu">

</div>
<div id="leftmenu">

</div>
</div>

<div class="Bodycontent">
<br />
<div class="normalblack"><div class="sh1">
<br />
<table border="0" align="center">
<tr>
<td><Font COLOR="#585858"><b>Methhod Local Inner Class<br></font></td>
</tr>
</table>

  </div>
  <table border="0" align="right">
<tr>
<td><Font COLOR="#585858"><font color="#980000">Posted On : 01-july-1988</font></font></td>
</tr>
</table>
<br /><br/>
 <span class="span" /> If we declare inner class inside a method, such type of inner class is called 'Method local inner class'. The scope of method local Inner class is with in the method only, in which it is declared. We can declare Inner class either in instance method or in static method. If we declare inside instance method,, we cam access both static and non static variables of outer class. if we declare inside static method, we can access only static members of outer class. see the following example.<br />
 <div class="Example"> 
<pre>
<font face="Verdana, Geneva, sans-serif">
<font color="#0000ff">class </font><font color="#000000">OuterClass </font>
<font color="#000000">{</font>
	<font color="#0000ff">int </font><font color="#000000">a=</font><font color="#800080">10</font><font color="#000000">, b=</font><font color="#800080">20</font><font color="#000000">;</font>
	<font color="#0000ff">public void </font><font color="#000000">inner()</font>
	<font color="#000000">{</font>
	<font color="#0000ff">class </font><font color="#000000">InnerClass</font>
	<font color="#000000">{</font>
		<font color="#0000ff">int </font><font color="#000000">a =</font><font color="#800080">30</font><font color="#000000">;</font>
		<font color="#0000ff">public void </font><font color="#000000">display()</font>
		<font color="#000000">{</font>
			<font color="#ff0000">System</font><font color="#000000">.out.println(b); </font><font color="#008000">// prints 20</font>
			<font color="#ff0000">System</font><font color="#000000">.out.println(</font><font color="#0000ff">this</font><font color="#000000">.a); </font><font color="#008000">// prints 30</font>
			<font color="#ff0000">System</font><font color="#000000">.out.println(OuterClass.</font><font color="#0000ff">this</font><font color="#000000">.a); </font><font color="#008000">// prints 10</font>
		<font color="#000000">}</font>
		
	<font color="#000000">}</font>
	<font color="#000000">InnerClass i = </font><font color="#0000ff">new </font><font color="#000000">InnerClass();</font>
	<font color="#000000">i.display();</font>
	<font color="#000000">}</font>
	<font color="#0000ff">public static void </font><font color="#000000">main(</font><font color="#ff0000">String </font><font color="#000000">as[])</font>
		<font color="#000000">{</font>
			<font color="#000000">OuterClass o = </font><font color="#0000ff">new </font><font color="#000000">OuterClass();</font>
			<font color="#000000">o.inner();</font>
		<font color="#000000">}</font>
	
<font color="#000000">}</font>
</font>
</pre>
</div>

 <br />
  <span class="span" />&#8226; in method local inner class, we can't access local variables of method in which we declared it. but if variable is declared as final, then we can access that variable. see the following example. <br />
 <div class="Example"> 
<pre>
<font face="Verdana, Geneva, sans-serif">
<font color="#0000ff">class </font><font color="#000000">OuterClass </font>
<font color="#000000">{</font>
	<font color="#0000ff">public void </font><font color="#000000">innerMethod()</font>
	<font color="#000000">{</font>
	<font color="#0000ff">int </font><font color="#000000">a =</font><font color="#800080">30</font><font color="#000000">;</font>
	<font color="#0000ff">final int </font><font color="#000000">b=</font><font color="#800080">50</font><font color="#000000">;</font>
	<font color="#0000ff">class </font><font color="#000000">InnerClass</font>
	<font color="#000000">{</font>
		<font color="#0000ff">public void </font><font color="#000000">display()</font>
		<font color="#000000">{</font>
		<font color="#008000">// System.out.println(a); // compile time error</font>
			<font color="#ff0000">System</font><font color="#000000">.out.println(b); </font><font color="#008000">// prints 50</font>
		<font color="#000000">}	</font>
	<font color="#000000">}</font>
	<font color="#000000">}	</font>
<font color="#000000">}</font>
</font>
</pre>
</div>
<br />
<span class="span" />&#8226; Method local inner class accepts only final, abstract, strictfp modifiers <br /><br />
 <span style="padding-left:150px" /> <font color="#0000FF">Preveous</font><span style="padding-left:250px" /><font color="#0000FF">Next</font>                            <br /> <br /><br />        
</div>
</div>
</hr>
<!--<hr color="#D8D8D8">-->
<div id="midbanner">
<div id="midbannerleft"></div>
</div>
<!--<hr color="#D8D8D8">-->
<div class="Bodycontent">
<div class="normalblack"><div class="Bodycontent1"><Font COLOR="#585858"><b>Jdbc introduction</b></Font></div>
other. These types of threads are called as asynchronous threads. But
there are two problems may be occur with asynchronous threadsdfghh... <a href="http://www.yahoo.com" style="text-decoration: none;"><font color="#6666EE">ClickHere</font></a>
</div>


</div>
<div class="Bodycontent">
<div class="normalblack"><div class="Bodycontent1"><Font COLOR="#585858"><b>Jdbc introduction</b></Font></div>
other. These types of threads are called as asynchronous threads. But
there are two problems may be occur with asynchronous threadsdfghh... <a href="http://www.yahoo.com" style="text-decoration: none;"><font color="#6666EE">ClickHere</font></a>
</div>

</div>
<div class="Bodycontent">
<div class="normalblack"><div class="Bodycontent1"><Font COLOR="#585858"><b>Jdbc introduction</b></Font></div>
other. These types of threads are called as asynchronous threads. But
there are two problems may be occur with asynchronous threadsdfghh... <a href="http://www.yahoo.com" style="text-decoration: none;"><font color="#6666EE">ClickHere</font></a>
</div>

</div>
<div class="Bodycontent">
<div class="normalblack"><div class="Bodycontent1"><Font COLOR="#000000">Jdbc introduction</Font></div>
other. These types of threads are called as asynchronous threads. But
there are two problems may be occur with asynchronous threadsdfghh... <a href="http://www.yahoo.com" style="text-decoration: none;"><font color="#6666EE">ClickHere</font></a>
</div>

</div>
<div class="Bodycontent">
<div class="normalblack"><div class="Bodycontent1"><Font COLOR="#000000">Jdbc introduction</Font></div>
other. These types of threads are called as asynchronous threads. But
there are two problems may be occur with asynchronous threadsdfghh... <a href="http://www.yahoo.com" style="text-decoration: none;"><font color="#6666EE">ClickHere</font></a>
</div>

</div>
<div class="Bodycontent">
<div class="normalblack"><div class="Bodycontent1"><Font COLOR="#000000">Jdbc introduction</Font></div>
other. These types of threads are called as <b>asynchronous threads</b>. But
there are two problems may be occur with asynchronous threadsdfghh... <a href="http://www.yahoo.com" style="text-decoration: none;"><font color="#6666EE">ClickHere</font></a>
</div>

</div>
<div class="Bodycontent">
<div class="normalblack"><div class="Bodycontent1"><Font COLOR="#6666EE">Jdbc introduction</Font></div>
other. These types of threads are called as <b>asynchronous threads</b>. But
there are two problems may be occur with asynchronous threadsdfghh... <a href="http://www.yahoo.com" style="text-decoration: none;"><font color="#6666EE">ClickHere</font></a>
</div>

</div>
<div class="Bodycontent">
<div class="normalblack"><div class="Bodycontent1"><Font COLOR="#6666EE">Jdbc introduction</Font></div>
other. These types of threads are called as <b>asynchronous threads</b>. But
there are two problems may be occur with asynchronous threadsdfghh... <a href="http://www.yahoo.com" style="text-decoration: none;"><font color="#6666EE">ClickHere</font></a>
</div>

</div>
<div class="Bodycontent">
<div class="normalblack"><div class="Bodycontent1"><Font COLOR="#6666EE">Jdbc introduction</Font></div>
other. These types of threads are called as <b>asynchronous threads</b>. But
there are two problems may be occur with asynchronous threadsdfghh... <a href="http://www.yahoo.com" style="text-decoration: none;"><font color="#6666EE">ClickHere</font></a>
</div>

</div>
</hr>
<div id="botbanner">
<div id="botbannerleft"></div>
</div>
<div class="Bodycontent">
<div class="Comment">
<form>
<div class="Comment"><textarea name="comment" placeholder="Enter your comment here..."
style="width:238px; height:50px;"></textarea></div><div class="Comment"><input type="text" name="name" placeholder="name (required)..." style="width:238px; height:20px;"></div>
<div class="Comment"><input type="text" name="mailId" placeholder="Email id (required)..." style="width:238px; height:20px;"></div>
<div class="Submit"><input type="submit" value="submit" onclick="writeComment(this.form)"></div>
</form>
</div>
</div>
<hr>
</div>

<div id="footer_index" style="margin-left:-0px;">

<p class="footer">

<a href="http://www.helenkellersinstitute.org/Index.html">Home</a>  |  <a href="http://www.helenkellersinstitute.org/about%20us.html">About us</a>  |  <a href="http://www.helenkellersinstitute.org/objectives.html">Advertise</a>  |  <a  href="http://www.helenkellersinstitute.org/contact%20us.html">Contact us </a> <br>
Site Designed and Developed by -- SreenuValireddi -- Copyrights © -All Rights Reserved</p>
</div>
</div>
</div>
</body></html>